<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
   
    <title>Awesome-pyecharts</title>
            <script type="text/javascript" src="https://assets.pyecharts.org/assets/echarts.min.js"></script>

</head>
<body>
    <div id="cb81dcecb8e147a1b2e4dd39302f2b7b" class="chart-container" style="width:100%; height:700px;"></div>
    <script>
        var chart_cb81dcecb8e147a1b2e4dd39302f2b7b = echarts.init(
            document.getElementById('cb81dcecb8e147a1b2e4dd39302f2b7b'), 'white', {renderer: 'canvas'});
        var option_cb81dcecb8e147a1b2e4dd39302f2b7b = {
    "animation": true,
    "animationThreshold": 2000,
    "animationDuration": 1000,
    "animationEasing": "cubicOut",
    "animationDelay": 0,
    "animationDurationUpdate": 300,
    "animationEasingUpdate": "cubicOut",
    "animationDelayUpdate": 0,
    "color": [
        "#c23531",
        "#2f4554",
        "#61a0a8",
        "#d48265",
        "#749f83",
        "#ca8622",
        "#bda29a",
        "#6e7074",
        "#546570",
        "#c4ccd3",
        "#f05b72",
        "#ef5b9c",
        "#f47920",
        "#905a3d",
        "#fab27b",
        "#2a5caa",
        "#444693",
        "#726930",
        "#b2d235",
        "#6d8346",
        "#ac6767",
        "#1d953f",
        "#6950a1",
        "#918597"
    ],
    "series": [
        {
            "type": "graph",
            "layout": "force",
            "symbolSize": 10,
            "circular": {
                "rotateLabel": false
            },
            "force": {
                "repulsion": 2500,
                "edgeLength": 50,
                "gravity": 0.2
            },
            "label": {
                "show": true,
                "position": "inside",
                "margin": 8,
                "formatter": function (x) { var strs = x.data.name;   var n='';    var str='centernode';   if(strs.search(str)!=-1) {return  n;}   var strs = x.data.name.split('|')[0];  if(strs.length<=6){                       return strs;                   }else {                       name = strs.slice(0,6) + '...';                        return name;                   }}
            },
            "lineStyle": {
                "width": 1,
                "opacity": 1,
                "curveness": 0,
                "type": "solid"
            },
            "roam": true,
            "draggable": true,
            "focusNodeAdjacency": "true",
            "data": [
                {
                    "name": "\u6beb\u65e0\u60c5\u611f\u53cd\u5e94|symptom",
                    "des": "\u6beb\u65e0\u60c5\u611f\u53cd\u5e94",
                    "category": 1,
                    "symbolSize": 90
                },
                {
                    "name": "accompany_disease|centernode",
                    "symbolSize": 30
                },
                {
                    "name": "desc|centernode",
                    "symbolSize": 30
                },
                {
                    "name": "\u60c5\u611f\u7684\u79cd\u7c7b\u5305\u62ec\u4f4e\u7ea7\u60c5\u611f\u548c\u9ad8\u7ea7\u60c5\u611f\u3002\u4f4e\u7ea7\u60c5\u611f\u53cd\u5e94\u53c8\u53eb\u505a\u5185\u6307\u5411\u6027\u60c5\u611f\u53cd\u5e94\uff0c\u9ad8\u7ea7\u60c5\u611f\u53cd\u5e94\u53c8\u53eb\u505a\u5916\u6307\u5411\u6027\u60c5\u611f\u53cd\u5e94\u3002\u60c5\u611f\u79cd\u7c7b\u51cf\u5c11\uff0c\n\u751a\u81f3\u6ca1\u6709\u3002\u5bf9\u4e8e \u7cbe\u795e\u5206\u88c2\u75c7 \u9634\u6027\u75c7\u72b6\u7684\u60a3\u8005\u6765\u8bf4\uff0c\u4e3b\u8981\u662f\u4eba\u683c\u3001\u60c5\u611f\u53cd\u5e94\u3001\u610f\u5fd7\u3001\u884c\u4e3a\u548c\u793e\u4f1a\u529f\u80fd\u7684\u969c\u788d\uff0c\u6bd4\u5982\u7f3a\u4e4f\u60c5\u611f\u3001\u7f3a\u4e4f\u59cb\u52a8\n\u6027\u3001\u8a00\u8bed\u8d2b\u4e4f\u3001\u5174\u8da3\u7f3a\u4e4f\u3001\u884c\u4e3a\u61d2\u6563\u3001\u793e\u4ea4\u9000\u7f29\u7b49\u3002|desc",
                    "des": "\u60c5\u611f\u7684\u79cd\u7c7b\u5305\u62ec\u4f4e\u7ea7\u60c5\u611f\u548c\u9ad8\u7ea7\u60c5\u611f\u3002\u4f4e\u7ea7\u60c5\u611f\u53cd\u5e94\u53c8\u53eb\u505a\u5185\u6307\u5411\u6027\u60c5\u611f\u53cd\u5e94\uff0c\u9ad8\u7ea7\u60c5\u611f\u53cd\u5e94\u53c8\u53eb\u505a\u5916\u6307\u5411\u6027\u60c5\u611f\u53cd\u5e94\u3002\u60c5\u611f\u79cd\u7c7b\u51cf\u5c11\uff0c\n\u751a\u81f3\u6ca1\u6709\u3002\u5bf9\u4e8e \u7cbe\u795e\u5206\u88c2\u75c7 \u9634\u6027\u75c7\u72b6\u7684\u60a3\u8005\u6765\u8bf4\uff0c\u4e3b\u8981\u662f\u4eba\u683c\u3001\u60c5\u611f\u53cd\u5e94\u3001\u610f\u5fd7\u3001\u884c\u4e3a\u548c\u793e\u4f1a\u529f\u80fd\u7684\u969c\u788d\uff0c\u6bd4\u5982\u7f3a\u4e4f\u60c5\u611f\u3001\u7f3a\u4e4f\u59cb\u52a8\n\u6027\u3001\u8a00\u8bed\u8d2b\u4e4f\u3001\u5174\u8da3\u7f3a\u4e4f\u3001\u884c\u4e3a\u61d2\u6563\u3001\u793e\u4ea4\u9000\u7f29\u7b49\u3002",
                    "category": 3,
                    "symbolSize": 70
                },
                {
                    "name": "\u53cd\u5e94\u6027\u6291\u90c1|disease",
                    "des": "\u53cd\u5e94\u6027\u6291\u90c1",
                    "category": 2,
                    "symbolSize": 70
                }
            ],
            "categories": [
                {},
                {
                    "name": "symptom"
                },
                {
                    "name": "disease"
                },
                {
                    "name": "desc"
                }
            ],
            "edgeLabel": {
                "show": true,
                "margin": 8,
                "formatter": function (x) {return x.data.name;}
            },
            "edgeSymbol": [
                "circle",
                "arrow"
            ],
            "edgeSymbolSize": [
                4,
                10
            ],
            "links": [
                {
                    "source": "\u6beb\u65e0\u60c5\u611f\u53cd\u5e94|symptom",
                    "target": "accompany_disease|centernode",
                    "name": "accompany_disease"
                },
                {
                    "source": "\u6beb\u65e0\u60c5\u611f\u53cd\u5e94|symptom",
                    "target": "desc|centernode",
                    "name": "desc"
                },
                {
                    "source": "desc|centernode",
                    "target": "\u60c5\u611f\u7684\u79cd\u7c7b\u5305\u62ec\u4f4e\u7ea7\u60c5\u611f\u548c\u9ad8\u7ea7\u60c5\u611f\u3002\u4f4e\u7ea7\u60c5\u611f\u53cd\u5e94\u53c8\u53eb\u505a\u5185\u6307\u5411\u6027\u60c5\u611f\u53cd\u5e94\uff0c\u9ad8\u7ea7\u60c5\u611f\u53cd\u5e94\u53c8\u53eb\u505a\u5916\u6307\u5411\u6027\u60c5\u611f\u53cd\u5e94\u3002\u60c5\u611f\u79cd\u7c7b\u51cf\u5c11\uff0c\n\u751a\u81f3\u6ca1\u6709\u3002\u5bf9\u4e8e \u7cbe\u795e\u5206\u88c2\u75c7 \u9634\u6027\u75c7\u72b6\u7684\u60a3\u8005\u6765\u8bf4\uff0c\u4e3b\u8981\u662f\u4eba\u683c\u3001\u60c5\u611f\u53cd\u5e94\u3001\u610f\u5fd7\u3001\u884c\u4e3a\u548c\u793e\u4f1a\u529f\u80fd\u7684\u969c\u788d\uff0c\u6bd4\u5982\u7f3a\u4e4f\u60c5\u611f\u3001\u7f3a\u4e4f\u59cb\u52a8\n\u6027\u3001\u8a00\u8bed\u8d2b\u4e4f\u3001\u5174\u8da3\u7f3a\u4e4f\u3001\u884c\u4e3a\u61d2\u6563\u3001\u793e\u4ea4\u9000\u7f29\u7b49\u3002|desc",
                    "name": " "
                },
                {
                    "source": "accompany_disease|centernode",
                    "target": "\u53cd\u5e94\u6027\u6291\u90c1|disease",
                    "name": " "
                }
            ],
            "tooltip": {
                "show": true,
                "trigger": "item",
                "triggerOn": "mousemove|click",
                "axisPointer": {
                    "type": "line"
                },
                "formatter": function (x) { if(x.dataType === 'edge'){return x.data.name;} var strs = x.data.des;  var str = ''; for(var i = 0, s; s = strs[i++];) { if(i==500){str+='...'; break;} str += s; if(!(i % 50)) str += '<br>'; } return str;},
                "textStyle": {
                    "fontSize": 14
                },
                "borderWidth": 0
            }
        }
    ],
    "legend": [
        {
            "data": [
                "",
                "symptom",
                "disease",
                "desc"
            ],
            "selected": {
                "": true,
                "symptom": true,
                "disease": true,
                "desc": true
            },
            "show": true,
            "padding": 5,
            "itemGap": 10,
            "itemWidth": 25,
            "itemHeight": 14
        }
    ],
    "tooltip": {
        "show": true,
        "trigger": "item",
        "triggerOn": "mousemove|click",
        "axisPointer": {
            "type": "line"
        },
        "textStyle": {
            "fontSize": 14
        },
        "borderWidth": 0
    },
    "title": [
        {
            "text": "\u6beb\u65e0\u60c5\u611f\u53cd\u5e94\u76f8\u5173\u77e5\u8bc6\u56fe\u8c31",
            "padding": 5,
            "itemGap": 10
        }
    ]
};
        chart_cb81dcecb8e147a1b2e4dd39302f2b7b.setOption(option_cb81dcecb8e147a1b2e4dd39302f2b7b);
    </script>
</body>
</html>
